dictcase = {"upcase": 0, "downcase": 0, "num": 0}
str = input("请输入")
for c in str:
    if 'A' <= c <= 'Z':
        dictcase["upcase"] += 1
    elif 'a' <= c <= 'z':
        dictcase["downcase"] += 1
    elif '0' <= c <= '9':
        dictcase["num"] += 1
print("大写字母{0}个,小写字母{1}个,数字{2}个".format(dictcase["upcase"],
                                        dictcase["downcase"], dictcase["num"]))
